package com.treeHole.treeHoleServer.mapper;


import com.treeHole.treeHoleServer.pojo.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface UserMapper {

    int insertUser(User user);

    //通过邮箱和密码查找用户,找到用户说明密码正确,返回用户id
    List<User> selectUserByEmailAndPassword(String email,String password);

    List<User> searchUserByEmail(String email);

    List<Integer> getUserIdByEmail(String email);
    //修改密码
    int modifyUserPassword(String email,String password);

    int modifyUserLastLoginTime(String email,String loginTime);
}
